
CC = g++ 
system ?= windows

ifeq ($(system), unix)
CPPFLAG = -g -D UNIX 
endif
ifeq ($(system), windows)
SHELL = cmd.exe
CPPFLAG = -g -D WINDOWS 
endif

# 伪目标
.PHONY: clean

all: vm

vm: main.cpp dev.cpp lc3.cpp 
	$(CC) $^ $(CPPFLAG) -o $@  

clean:
ifeq ($(system), unix)
	-rm -f vm 
endif
ifeq ($(system), windows)
	-del vm.exe
endif
